Field of the Invention
The present disclosure generally relates to electronics and, more particularly, to an electronic device which detects a touch operation, a control method thereof, and a storage medium. In particular, the present disclosure relates to a control technology capable of reducing malfunctions due to unintentional touches by a user.
Description of the Related Art
In a device having a touch panel which detects a touch operation, an unintentional function may be executed according to detection of a touch, even thorough the touch is an unintentional touch by a user. As a method for preventing a malfunction caused by an operation due to an unintentional touch by a user, there is one in which a function is not executed according to a touch operation made on a wide contact area (surface contact). Japanese Patent Application Laid-Open No. 2011-2891 describes that when a touch operation input to an area equal to or greater than a predetermined area on the touch panel is detected, such an input is invalidated. Further, Japanese Patent Application Laid-Open No. 2014-203183 discloses that predetermined areas on right and left edges of a touch panel where a user tends to touch unintentionally when holding the device are set to be object areas, and if a touch area on the object areas is equal to or greater than a threshold, a touch operation performed on the entire touch panel is invalidated.
As an exemplary case where an unintentional touch by a user is made, there is a case where a user carries a device such as a digital camera by hanging it from the neck or shoulder. When the user walks around with the device hung from the neck or shoulder in the case where the surface of the touch panel of the device is tilted against the user, surface contact is likely to be made on a partial area rather than the entire touch panel. Further, when the user performs a touch operation, it is likely that the device is tilted. If the entire touch panel is handled as an object area for determination as described in Japanese Patent Application Laid-Open No. 2011-2891, when a touch operation having a large touch area is performed intentionally, there is a possibility that it is detected as surface contact, although it is an intentional operation by the user. On the other hand, if the surface of the touch panel is in parallel with the user when the user walks around with the device hung from the neck or shoulder, the center area of the touch panel is likely to be in surface contact. If edge areas of a touch panel, which are likely to be in contact when the casing is held, is set as areas for detecting surface contact, as described in Japanese Patent Application Laid-Open No. 2014-203183, an unintentional touch on the center area of the touch panel may not be detected as surface contact even if it is an unintentional touch by a user.